import React,{useState} from 'react'
import './Distributedata.css'
const Distributedata: React.FC = () => {
  const [acticeid,setacticeid]=useState('我参与的')

  const rendersix=()=>{
    switch (acticeid){
        case '我发起的':
          return <div className='mysend'>
              <div className='havecontent'>
                <img src="https://www.eqxiu.com/workbench/img/empty.143a1468.png" alt="" />
                <p>当前暂无团队,快去创建吧</p>
                <button>创建团队</button>
              </div>
          </div>;
         case '我参与的':
          return <div className='participate'>
              <div className='nocontent'>
                   <img src="https://www.eqxiu.com/workbench/img/empty.143a1468.png" alt="" />
                   <p>还没有参与作品分发</p>
              </div>
          </div>;
          default:
            return null 
    }
  }


  return (
    <div className='distributebox'>
        <div className='distributebox_hed'>
            <p onClick={()=>setacticeid('我发起的')}>我发起的</p>
            <p onClick={()=>setacticeid('我参与的')}>我参与的</p>
        </div>

        <div className='distributebox_bom'>
          {rendersix()}
        </div>

    </div>
  )
}

export default Distributedata
